package com.hotchpotch.adapter;

import android.content.Context;
import android.widget.TextView;

import com.hotchpotch.R;
import com.hotchpotch.base.BaseRecyclerAdapter;
import com.hotchpotch.base.BaseViewHolder;
import com.hotchpotch.bean.KillServiceLogBean;
import com.hotchpotch.util.MyUtil;

public class KillServiceAdapter extends BaseRecyclerAdapter<KillServiceLogBean> {
    private TextView tv1, tv2;

    public KillServiceAdapter(Context context, int layoutId) {
        super(context, layoutId);
    }

    @Override
    public void onBind(BaseViewHolder holder, KillServiceLogBean killServiceLogBean, int position) {
        tv1 = holder.getView(R.id.item_killservice_tv1);
        tv2 = holder.getView(R.id.item_killservice_tv2);

        tv1.setText(MyUtil.getDateToString(Long.parseLong(killServiceLogBean.getTime())));
        tv2.setText(killServiceLogBean.getContent());
    }
}
